package models

// Suggestion 建议表
type Suggestion struct {
	BaseModel
	UserID  uint   `gorm:"index" json:"user_id"`
	Content string `gorm:"type:text;not null" json:"content"`
	Contact string `gorm:"size:100" json:"contact"`
	Status  string `gorm:"size:20;default:待处理" json:"status"`
	Reply   string `gorm:"type:text" json:"reply"`

	// 关联
	User User `gorm:"foreignKey:UserID" json:"user,omitempty"`
}

func (Suggestion) TableName() string {
	return "go_suggestion"
}
